﻿namespace DingTalk.Extensions.Model
{
    /// <summary>
    /// 通用返回信息类
    /// </summary>
    public class MessageModel<T>
    {
        public MessageModel()
        {
        }
        public MessageModel(string message, bool isSuccess, T responseData)
        {
            this.msg = message;
            this.success = isSuccess;
            this.response = responseData;
        }
        /// <summary>
        /// 状态码
        /// </summary>
        public int status { get; set; } = 200;
        /// <summary>
        /// 操作是否成功
        /// </summary>
        public bool success { get; set; } = false;
        /// <summary>
        /// 返回信息
        /// </summary>
        public string msg { get; set; } = "服务器异常";
        /// <summary>
        /// 返回状态码(bindmobile:绑定手机号)
        /// </summary>
        public string code { get; set; } = "";
        /// <summary>
        /// 返回数据集合
        /// </summary>
        public T response { get; set; }

        /// <summary>
        /// 返回附赠数据
        /// </summary>
        public object data { get; set; }

        public object data2 { get; set; }

        public object data3 { get; set; }

    }
}
